package com.example.yang.yixin.FragmentManager;

import android.os.Bundle;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.v4.app.Fragment;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.Toast;

import com.example.yang.yixin.R;
import com.example.yang.yixin.Views.AnnularView;

public class Fragment_person extends Fragment {
    private Float[] datas = new Float[3];
    AnnularView annularView;
    @Nullable
    @Override
    public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
        View view=inflater.inflate(R.layout.fragment_person,container,false);
        annularView=view.findViewById(R.id.view_count);
        float one=Float.valueOf(getArguments().getString("one"));
        float two=Float.valueOf(getArguments().getString("two"));
        float three=Float.valueOf(getArguments().getString("three"));
        float a= (float) 0.0;
        float b=(float)1.0;
        datas[0]=one;//绿色
        datas[1]=three;//红色
        datas[2]=two;//黄色
        Log.d("one",one+"");
        Log.d("two",two+"");
        Log.d("three",three+"");
        annularView.setDatas(datas,true);
        return view;
    }
}
